//package com.imchen.cms.utils;
//
//import com.auth0.jwt.JWT;
//import com.auth0.jwt.algorithms.Algorithm;
//import com.imchen.cms.constant.CMS;
//import com.imchen.cms.model.User;
//
//import java.util.Date;
//
///**
// * @author imchen
// * @create: 2019-01-14 06:12
// **/
//public class JWTUtil {
//
//    public static String getToken(User user) {
//        String token = "";
//        token = JWT.create().withAudience(user.getId().toString())
//                .withExpiresAt(new Date(System.currentTimeMillis()+ CMS.TOKEN_EXPIRE_TIME))
//                .withIssuer("imc")
//                .withSubject("lavande")
//                .sign(Algorithm.HMAC256(user.getPassword()));
//        return token;
//    }
//
//}
